/**
 * Created by zhangqingxi on 2017-04-06.
 */
var modelPath=ROOT_PATH+'/environmental/monitor/personnel/';



function initUser() {
    $("#userName").textbox({
        iconWidth: 22,
        icons: [{
            iconCls: 'icon-add',
            handler: function (e) {
                add_contractorInfo_func();
            }
        }, {
            iconCls: 'icon-remove',
            handler: function (e) {
                $(e.data.target).textbox('clear');
                $('#userId').val('');

            }
        }]
    });
}
function add_contractorInfo_func() {
    WindowManager.openLayer({
        type: 2,
        title: '选择人员信息',
        area: ['1150px', '70%'],
        content: ROOT_PATH + '/permission/user/simpleList.shtml?isMulti=0',
        callBack:function(data){//窗口关闭后的回调函数
            var id=data[0].id;
            var name=data[0].realName;

            $('#userId').val(id);
            $('#userName').textbox('setValue',name);

        }
    });

}
